module: Avoid ABI changes when debug info is disabled
authorBen Hutchings <benh@debian.org>
Wed, 2 Mar 2022 20:22:28 +0000 (21:22 +0100)
committerSalvatore Bonaccorso <carnil@debian.org>
Tue, 15 Mar 2022 06:54:31 +0000 (06:54 +0000)
commit3f94c9ecb4a4d6a5f04886a3d6a52719c2689869
tree3f2a98848f11115faad194e4f36b24413d92486b
parent548f9a0f3e6960358b7f3104ea415792a05f235b
module: Avoid ABI changes when debug info is disabled

Forwarded: not-needed

CI builds are done with debug info disabled, but this removes some
members from struct module and replaces some BTF-related exports with
static definitions.  This causes builds to fail if there is an ABI
reference for the current ABI.

- Add a new config symbol DEBUG_INFO_BTF_MODULES_NOOP which can be
  enabled when DEBUG_INFO is not enabled
- When the symbol is enabled:
  - Define the BTF-related members of struct module
  - Export the no-op definitions of BTF-related functions
  - Define and export the same BTF-related static lists

Gbp-Pq: Topic debian
Gbp-Pq: Name module-avoid-abi-changes-when-debug-info-is-disabled.patch
include/linux/btf.h
include/linux/module.h
kernel/bpf/btf.c
lib/Kconfig.debug